export interface DeviceItem {
  id?: string;
  name?: string;
  targetKey?: string;
  sort?: string | number;
  maxValue?: string;
  minValue?: string;
  valueArr?: string;
  fixedValue?: string;
  targetType?: string;
  unit?: string;
  icon?: string;
}

/**
 * 返回表单类型
 */
export interface DeviceVO {
  id: string | number;
  name: string;
  sn: string;
  mac: number;
  categoryIds: string;
  brandId: string;
  sort: string | number;
  status: string | number;
  activationTime: string;
  targetId: string;
  details: string;
  onLine: string | number;
  onLineTime: string;
  category: string;
  items: [DeviceItem];
  settingTemperatureBo?: SettingQuery;
  settingElectricBo?: SettingQuery;
  settingEnvironmentBo?: SettingQuery;
}
/**
 * 表单类型
 */
export interface DeviceForm extends BaseEntity {
  id?: string | number;
  name?: string;
  sn?: string;
  mac?: number;
  categoryIds?: string;
  brandId?: string;
  sort?: string | number;
  status?: number | string;
  activationTime?: string;
  targetId?: string;
  details?: string;
  onLine?: number | string;
  onLineTime?: string;
  items?: [DeviceItem];
  settingTemperatureBo?: SettingQuery;
  settingElectricBo?: SettingQuery;
  settingEnvironmentBo?: SettingQuery;
}
/**
 * 搜素 数据类型
 */
export interface DeviceQuery extends PageQuery {
  onLine?: string | number;
  name?: string | number;
  mac?: number | string;
}
/**
 * 获取设备全部 在线 离线的状态的数量
 */
export interface DeviceCountVO {
  label: string;
  count: number | string;
  icon?: string;
}

/**
 * 设置 数据类型
 */
export interface SettingQuery {
  deviceId: string | number;
  value?: number;
  temperature?: number;
  humidity?: number;
  sensitivity?: number;
  remindTime?: number;
}
